package com.iretailer.report.model;

import com.iretailer.report.util.TimeUtil;
import lombok.Data;

import java.time.ZonedDateTime;

/**
 * @Program: report
 * @Description:
 * @Author: Bennie
 * @Date: 2021-02-04 17:40
 **/

@Data
public class AlarmEasModel {

    private Integer deviceId;

    private ZonedDateTime time;

    private Integer alertTimes;

    private String epc;

    private Integer rssi;

    private Integer ruleNum;

    public String getKey() {
        return deviceId + "_" + TimeUtil.zoneDateTime_format(time, "yyyyMMddHHmm") + "_" + (time.getSecond() / 4);
    }
}
